<?php
	include_once 'autoload.php';
	

	session_start();

	$ctl = new MUploadCtl();
	$ctl->checkLogged();
	$ctl->checkNotReadonly();
	$ctl->proceed();
	
	$header = new Header();
	$header->render('Multiple upload');

	$form = $ctl->getMUploadForm();
	
	$albumId = $form->getAlbumId();
	$albumName = $form->getAlbumName();

	
?>
<form method="post" enctype="multipart/form-data">
<input type="hidden" name="pagename" value="mupload" id="pgid">
<input type="hidden" name="metname" value="" id="metid">

<input type="hidden" name="albumId" value="<?php echo $albumId; ?>">
<input type="hidden" name="albumName" value="<?php echo $albumName; ?>">

<h2>Multiple Upload</h2>
<h2>Album: <?php echo htmlspecialchars($albumName); ?></h2>
<table cellspacing="0" cellpadding="2">
  <thead>
  <tr>
    <td>Comments</td>
    <td>Picture</td>
  </tr>
  </thead>
  <tbody>
  <tr>
    <td>&nbsp;</td>
    <td><input style="color:white; " type="file" multiple="yes" name="picturefile[]" ></td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>
	    <input type="button" value="Submit" onclick="triggerform('submit')" class="enter">
	    <input type="button" value="Cancel" onclick="triggerform('cancel')" class="escape">
    </td>
  </tr>
  </tbody>
</table>
</form>
<?php
	$footer = new Footer();
	$footer->render();
?>
